<h1 itemprop="name" class="titulo">
    Resumo do Orçamento
</h1>
<div class="cnt-texto car_res_orc">
    <form id="form" method="post" action="<?php echo $this->urlbase.'/'.$this->controller.'/confirmacao'; ?>" enctype="multipart/form-data">
        
        <table>
            <tr>
                <td width="80px">Empresa</td>
                <td colspan="3" width="380px"><input type="text" name="sol_emp" value="" style="width: 350px;" required="" /></td>
                
                <td width="80px">Solicitante</td>
                <td colspan="3"><input type="text" name="sol_nom" value="" style="width: 350px;" required="" /></td>
            </tr>
            <tr>
                <td>Telefone</td>
                <td><input type="text" name="sol_tel" value="" style="width: 141px" required="" class="telefone" /></td>
                
                <td>E-mail</td>
                <td><input type="text" name="sol_eml" value="" style="width: 141px"required="" class="email" /></td>
                
                <td>Cidade</td>
                <td width="188px"><input type="text" name="sol_cid" value="" style="width: 141px" /></td>
                
                <td style="text-align: right;padding-right: 5px;">UF</td>
                <td><input type="text" name="sol_uf" value="" style="width: 141px" /></td>
            </tr>
            <tr>
                <td>Observação</td>
                <td colspan="7"><textarea name="sol_obs" rows="4" style="width: 810px;"></textarea></td>
            </tr>
            
        </table>
        
        <div class="cnt_produto">
            
            <div class="til">Produto selecionado</div>
            <div class="left foto">
                <?php
                    $img_tab = glob('public/upload/produto/'.$this->produto['PRO_ID'].'_*_dp.*');
                    if(isset($img_tab[0])){ 
                ?>
                <img src="<?php echo $this->urlbase.'/'.$img_tab[0]; ?>" width="200" />
                <?php } ?>
            </div>
            <div class="left info_det">
                <p><?php echo $this->produto['PRO_DES']; ?></p>
                
                <p><label>Cor</label>
                <?php $img = glob('public/upload/cor/'.$this->cores['COR_ID'].'.*');
                    if(!isset($img[0]) && strlen($this->cores['COR_COR']) > 0) { ?>
                    <span style="background-color: #<?php echo $this->cores['COR_COR']; ?>" class="cnt_cor" title="<?php echo $this->cores['COR_NOM']; ?>"></span>
                <?php } elseif(isset($img[0])) { ?>
                    <img src="<?php echo $this->urlbase.'/'.$img[0]; ?>" class="img_cor" title="<?php echo $this->cores['COR_NOM']; ?>" />
                <?php } ?>                   
                </p> 
                
               
                <p><label>Cor Detalhe</label> 
                    <?php 
                    if(is_array($this->carrinho['crd_id']))
                    foreach($this->carrinho['crd_id'] as $cdet) { 
                        //$obj = new Sistema_Model_DbTable_Cordetalhe();
                        //$cordet = $obj->fetchRow('CRD_ID = '.$cdet.' and CRD_STA = 1');
                        $query = 'SELECT SQL_CACHE CRD_ID, CRD_COR FROM CORDETALHE WHERE CRD_ID = '.$cdet.' and CRD_STA = 1';
                        $cordet = $this->db->fetchRow($query);
                        
                    $img = glob('public/upload/cordetalhe/'.$cordet['CRD_ID'].'.*');
                    if(!isset($img[0]) && strlen($cordet['CRD_COR']) > 0) { ?>
                    <span style="background-color: #<?php echo $cordet['CRD_COR']; ?>" class="cnt_cor" title="<?php echo $cordet['CRD_NOM']; ?>"></span>
                    <?php } elseif(isset($img[0])) { ?>
                        <img src="<?php echo $this->urlbase.'/'.$img[0]; ?>" class="img_cor" title="<?php echo $cordet['CRD_NOM']; ?>" />
                    <?php } } ?>
                </p>
                
                <p><label>Quantidade Total</label><?php echo $this->carrinho['qtd']; ?><p>
                
                <p><label>Tamanhos</label></p>
                    <ul class="grd_tam">
                    <?php
                        foreach($this->carrinho['tam_id'] as $tam) {
                            //$tm = new Sistema_Model_DbTable_Tamanhos();
                            //$tm = $tm->fetchRow('TAM_ID = '. $tam);
                            $query = 'SELECT SQL_CACHE TAM_ID, TAM_NOM FROM TAMANHOS WHERE TAM_ID = '. $tam;
                            $tm = $this->db->fetchRow($query);
                        ?>
                        <li><span><?php echo $tm['TAM_NOM']; ?></span> <input type="text" name="tam[<?php echo $tm['TAM_ID']; ?>]" value="" maxlength="4" class="numero" /></li>
                        <?php } ?>
                    </ul>
                
                
                <p><label>Enviar Arquivo</label> <input type="file" name="sol_fil" value="" style="width:240px" /></p>
                
                <img src="<?php echo $this->urlbase; ?>/public/media/images/loader.gif" class="loading" />
                
                <a href="javascript:void(0)" class="btn_conf cr_bk_pdr">Enviar</a>
                <?php /*
                <input type="submit" class="btn_conf cr_bk_pdr" name="Enviar">
                 */ ?>
                 
            </div>    
        </div>
        
        
    </form>

</div>
<div id="script"></div>
